import config from "@/config"
import http from "@/utils/request"

export default {
	monitorMonitor: {
		lists: {
			url: `${config.API_URL}/adminapi/monitor.monitor/lists`,
			name: "查看监控列表",
			get: async function(params){
                return await http.get(this.url, params);
            }
		},
		add: {
			url: `${config.API_URL}/adminapi/monitor.monitor/add`,
			name: "添加监控",
			post: async function(data={}){
				return await http.post(this.url, data);
			}
		},
		edit: {
			url: `${config.API_URL}/adminapi/monitor.monitor/edit`,
			name: "编辑监控",
			post: async function(data={}){
				return await http.post(this.url, data);
			}
		},
        delete: {
			url: `${config.API_URL}/adminapi/monitor.monitor/delete`,
			name: "编辑监控",
			post: async function(data={}){
				return await http.post(this.url, data);
			}
		},
        detail: {
			url: `${config.API_URL}/adminapi/monitor.monitor/detail`,
			name: "监控详情",
			post: async function(data={}){
				return await http.post(this.url, data);
			}
		},
        update_status: {
			url: `${config.API_URL}/adminapi/monitor.monitor/updateStatus`,
			name: "更改监控状态",
			post: async function(data={}){
				return await http.post(this.url, data);
			}
		},
	},
    getMonitor:{
        list:{
            url: `${config.API_URL}/adminapi/monitor.Field/lists`,
			name: "查看实时监控列表",
			get: async function(data={}){
				return await http.get(this.url, data);
			}
        },
        listAll:{
            url: `${config.API_URL}/adminapi/monitor.Equdate/log`,
			name: "查看实时监控列表所有",
			get: async function(data={}){
				return await http.get(this.url, data);
			}
        },
        edit: {
			url: `${config.API_URL}/adminapi/monitor.Field/edit`,
			name: "编辑实时监测显示",
			post: async function(data={}){
				return await http.post(this.url, data);
			}
		},
        tableImg: {
			url: `${config.API_URL}/adminapi/monitor.Equdate/lists`,
			name: "开机率/利用率",
			get: async function(data={}){
				return await http.get(this.url, data);
			}
		},
    },
    deviceMain:{
        url: `${config.API_URL}/adminapi/report.Maintenance/lists`,
			name: "设备维修统计",
			post: async function(data={}){
				return await http.post(this.url, data);
			}
    },
    deviceTable:{
        url: `${config.API_URL}/adminapi/report.Check/lists`,
        name: "设备点检表",
        post: async function(data={}){
            return await http.post(this.url, data);
        }
    },
    equTable:{
        url: `${config.API_URL}/adminapi/report.Equ/lists`,
        name: "开机率/利用率统计",
        post: async function(data={}){
            return await http.post(this.url, data);
        }
    },
    correspond: {
		list: {
			url: `${config.API_URL}/adminapi/device.Correspond/lists`,
			name: "设备对应列表",
			get: async function(params){
                return await http.get(this.url, params);
            }
		},
		add: {
			url: `${config.API_URL}/adminapi/device.Correspond/chageData`,
			name: "设备对应设置",
			post: async function(data={}){
				return await http.post(this.url, data);
			}
		},
        detail: {
			url: `${config.API_URL}/adminapi/device.Correspond/detail`,
			name: "设备对应详情",
			post: async function(data={}){
				return await http.post(this.url, data);
			}
		},
        status: {
			url: `${config.API_URL}/adminapi/device.Correspond/deviceStatus`,
			name: "设备状态分布",
			post: async function(data={}){
				return await http.post(this.url, data);
			}
		},
        data: {
			url: `${config.API_URL}/adminapi/device.Correspond/deviceData`,
			name: "设备数据",
			post: async function(data={}){
				return await http.post(this.url, data);
			}
		},
	},
}
